package controller;

import java.awt.Point;
import java.util.List;

public interface HumanControlledGame {

	/**
	 * Sets game board according to two-players game layout
	 */
	public void setTowPlayersBoard();
	
	/**
	 * Gets a position on board an returns a list of all positions that the piece at given position
	 * can move to.
	 * If there is no piece at given position, an empty list is returned
	 * @param srcPosition- position of the piece that should be moved
	 * @return list of positions where the piece can move to
	 */
	public List<Point> getNextMove(Point srcPosition);
	
	/**
	 * Moves the piece at given source position to the destination position.
	 * If there is no piece at source position or destination position is not in piece's
	 * moves list, no move is done and False is returned.
	 * If piece at given position is not assigned to current player, no move is done and False is returned.
	 * Otherwise, piece is moved and True is returned 
	 * @param srcPosition- position of the piece that should be moved
	 * @param destPosition- position where the piece should be moved to
 	 * @return True if could move piece, False if not
	 */
	 public boolean makeMoveHuman(Point srcPosition, Point destPosition);
	
	 /**
	  * Orders computer to randomly choose a piece and one possible move.
	  * After piece and valid move where chosen, move is done.
	  * Piece is chosen according to the player that should play at current turn
	  */
	 public Move makeMoveComputer();
	 
	/**
	 * Confirms if game is in Check state
	 * @return True if in Check, False if not
	 */
	public boolean isCheck();
	
	/**
	 * Confirms if game is in Stalemate state
	 */
	public boolean isStalemate();
	
	/**
	 * Confirms if game is in Checkmate state
	 * @return True if in Check, False if not
	 */
	public boolean isCheckmate();
}